/**
 * 再items里找到符合question和selectLib的item
 * @param {*} items 总的题库，里面是一个个对象数组
 * @param {*} selectLib 选择的题库
 * @param {*} question 选择的问题
 */
let findItem = async function findItem(tiku, selectLib, question) {
  for (let a = 2; a < tiku.length; a++) {
    let item = JSON.parse(tiku[a]);
    if (item.name == selectLib) {
      //找到对应题目所处的科目
      let title = item.title
      for (let i = 0; i < title.length; i++) {
        let getTitle = title[i];
        if (getTitle.question == question) {
          return getTitle;
        }
      }
    }
  }
};



export default {
  findItem
};
